We present a scanning transmission x-ray microscopy setup combined with a novel microwave synchronization scheme in order to study high frequency magnetization dynamics at synchrotron light sources. The sensitivity necessary to detect small changes of the magnetization on short time scales and nanometer spatial dimensions is achieved by combination of the developed excitation mechanism with a single photon counting electronics that is locked to the synchrotron operation frequency. The required mechanical stability is achieved by a compact design of the microscope. Our instrument is capable of creating direct images of dynamical phenomena in the 5-10 GHz range, with 35 nm resolution. When used together with circularly polarized x-rays, the above capabilities can be combined to study magnetic phenomena at microwave frequencies, such as ferromagnetic resonance (FMR) and spin waves. We demonstrate the capabilities of our technique by presenting phase resolved images of a 6 GHz nanoscale spin wave generated by a spin torque oscillator, as well as the uniform ferromagnetic precession with ~0.1 deg amplitude at 9 GHz in a micrometer-sized cobalt strip.